package com.vay.de.dang.online.view;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.FrameLayout;

import com.vay.de.dang.online.R;

public class DialogBottom extends DialogBase {

    private FrameLayout container;

    public DialogBottom(Context context) {
        super(context);
        super.setContentView(R.layout.dialog_bottom);
        autoWidth(1.0f);
        container = findViewById(R.id.container);
        setCanceledOnTouchOutside(false);
        setCancelable(false);
    }

    @Override
    public void setContentView(int layoutResID) {
        View content = LayoutInflater.from(getContext()).inflate(layoutResID, null);
        container.addView(content, new FrameLayout.LayoutParams(FrameLayout.LayoutParams.MATCH_PARENT,
                FrameLayout.LayoutParams.WRAP_CONTENT));
    }
}
